import { PrismaService } from '@app/prisma';
import { TeacherEntity } from '@app/prisma/teacher.entity/teacher.entity';
import { Query, Resolver } from '@nestjs/graphql';

@Resolver()
export class AnalysisResolver {
    constructor(
        private readonly prisma: PrismaService
    ) { }

    @Query(() => [TeacherEntity])
    async teacherAnalysis() {
        const a = await this.prisma.teacher.findMany({
            include: {
                TaskOnTeacherItem: true
            }
        })
        console.log(a[0].TaskOnTeacherItem)
        return a;
    }


}
